# 确保运行 `pod lib lint oneCommonLib.podspec` 以验证此 spec 文件的有效性
#
# 以 # 开头的行是可选的，但建议使用
# 要了解更多关于 Podspec 的信息，请参阅 https://guides.cocoapods.org/syntax/podspec.html
#

# 定义新的 Pod 规范
Pod::Spec.new do |s|

  # 指定 Pod 的名称
  s.name             = 'oneCommonLib'
  # 指定 Pod 的版本
  s.version          = '0.1.4'
  # 提供 Pod 的简短描述
  s.summary          = '简短描述'

  # 提供 Pod 的详细描述
  s.description      = '详细描述'

  # 指定 Pod 的主页
  s.homepage         = 'https://github.com/Cansing/oneCommonLib'
  # 可选：指定截图 URL
  # s.screenshots    = 'www.example.com/screenshots_1', 'www.example.com/screenshots_2'
  # 指定 Pod 的许可证
  s.license          = { :type => 'MIT', :file => 'LICENSE' }
  # 指定 Pod 的作者
  s.author           = { 'Cansing' => 'Cansing@163.com' }
  # 指定 Pod 的源代码位置
  s.source           = { :git => 'https://gitee.com/cansng/oneCommonLib.git', :tag => s.version.to_s }
  # 可选：指定社交媒体 URL
  # s.social_media_url = 'https://twitter.com/<TWITTER_USERNAME>'

  # 指定支持的 iOS 最低版本
  s.ios.deployment_target = '12.0'

  # 定义 'Tools' 子规范
  s.subspec 'Tools' do |ss|
    # ss.source_files = 'oneCommonLib/Tools/*.{h,m}'

    # 定义 'NSObject' 子规范
    ss.subspec 'NSObject' do |sss|
      sss.source_files = 'oneCommonLib/Tools/NSObject/**/*.{h,m}'      
    end
     
    # 定义 'Header' 子规范
    ss.subspec 'Header' do |sss|
      sss.source_files = 'oneCommonLib/Tools/Header/*.{h,m}'
      sss.dependency 'oneCommonLib/Tools/TXAdapter'
    end

    # 定义 'TXAdapter' 子规范
    ss.subspec 'TXAdapter' do |sss|
      sss.source_files = 'oneCommonLib/Tools/TXAdapter/**/*.{h,m}'
    end

    # 定义 'LogFilesManager' 子规范
    ss.subspec 'LogFilesManager' do |sss|
      sss.source_files = 'oneCommonLib/Tools/LogFilesManager/**/*.{h,m}'
    end

    # 定义 'Category' 子规范
    ss.subspec 'Category' do |sss|
      sss.source_files = 'oneCommonLib/Tools/Category/**/*.{h,m}'
      sss.dependency 'oneCommonLib/Tools/Header'
    end

    # 定义 'QiCodeReader' 子规范
    ss.subspec 'QiCodeReader' do |sss|
      sss.source_files = 'oneCommonLib/Tools/QiCodeReader/**/*.{h,m}'
      # sss.dependency 'oneCommonLib/Tools/LogFilesManager'
      sss.dependency 'oneCommonLib/Tools/Header'
      sss.dependency 'oneCommonLib/Tools/TXAdapter'
    end

    # 定义 'OneTextFiledView' 子规范
    ss.subspec 'OneTextFiledView' do |sss|
      sss.source_files = 'oneCommonLib/Tools/OneTextFiledView/**/*.{h,m}'
      sss.dependency 'oneCommonLib/Tools/Header'
      sss.dependency 'oneCommonLib/Tools/Category'
    end

    # 定义 'MMWebView' 子规范
    ss.subspec 'MMWebView' do |sss|
      sss.source_files = 'oneCommonLib/Tools/MMWebView/**/*.{h,m}'
      sss.dependency 'oneCommonLib/Tools/Header'
      sss.dependency 'oneCommonLib/Tools/TXAdapter'
      sss.dependency 'oneCommonLib/Tools/Category'
      sss.dependency 'oneCommonLib/Tools/LogFilesManager'
    end

    # 定义 'MJRefreshEX' 子规范
    ss.subspec 'MJRefreshEX' do |sss|
      sss.source_files = 'oneCommonLib/Tools/MJRefreshEX/**/*.{h,m}'
      # sss.dependency 'oneCommonLib/Tools/Header'
      sss.dependency 'oneCommonLib/Tools/TXAdapter'
      # sss.dependency 'oneCommonLib/Tools/Category'
      # sss.dependency 'oneCommonLib/Tools/LogFilesManager'
    end

    # 定义 'JQMapKit' 子规范
    ss.subspec 'JQMapKit' do |sss|
      sss.source_files = 'oneCommonLib/Tools/JQMapKit/**/*.{h,m}'
      sss.dependency 'oneCommonLib/Tools/Header'
      sss.dependency 'oneCommonLib/Tools/TXAdapter'
      # sss.dependency 'oneCommonLib/Tools/Category'
      sss.dependency 'oneCommonLib/Tools/LogFilesManager'
      sss.dependency 'oneCommonLib/Tools/NSObject'
    end

    # 定义 'JPQCodeTool' 子规范
    ss.subspec 'JPQCodeTool' do |sss|
      sss.source_files = 'oneCommonLib/Tools/JPQCodeTool/**/*.{h,m}'
      # sss.dependency 'oneCommonLib/Tools/Header'
      # sss.dependency 'oneCommonLib/Tools/TXAdapter'
      # sss.dependency 'oneCommonLib/Tools/Category'
      # sss.dependency 'oneCommonLib/Tools/LogFilesManager'
    end

    # 定义 'JKCountDownButton' 子规范
    ss.subspec 'JKCountDownButton' do |sss|
      sss.source_files = 'oneCommonLib/Tools/JKCountDownButton/**/*.{h,m}'
      sss.dependency 'oneCommonLib/Tools/Header'
      # sss.dependency 'oneCommonLib/Tools/TXAdapter'
      sss.dependency 'oneCommonLib/Tools/Category'
      # sss.dependency 'oneCommonLib/Tools/LogFilesManager'
    end

    # 定义 'Device' 子规范
    ss.subspec 'Device' do |sss|
      sss.source_files = 'oneCommonLib/Tools/Device/**/*.{h,m}'
    end

    # 定义 'BRPickerView' 子规范
    ss.subspec 'BRPickerView' do |sss|
      sss.source_files = 'oneCommonLib/Tools/BRPickerView/**/*.{h,m}'
      sss.dependency 'oneCommonLib/Tools/Header'
      # sss.dependency 'oneCommonLib/Tools/TXAdapter'
      sss.dependency 'oneCommonLib/Tools/Category'
      sss.dependency 'oneCommonLib/Tools/LogFilesManager'
    end

    # 定义 'Album' 子规范
    ss.subspec 'Album' do |sss|
      sss.source_files = 'oneCommonLib/Tools/Album/**/*.{h,m}'
      sss.dependency 'oneCommonLib/Tools/Header'
      # sss.dependency 'oneCommonLib/Tools/TXAdapter'
      sss.dependency 'oneCommonLib/Tools/Category'
      # sss.dependency 'oneCommonLib/Tools/LogFilesManager'
    end

    # 定义 'TCCommentsPopView' 子规范
    ss.subspec 'TCCommentsPopView' do |sss|
      sss.source_files = 'oneCommonLib/Tools/弹出框/**/*.{h,m}'
      # sss.dependency 'oneCommonLib/Tools/Header'
      # sss.dependency 'oneCommonLib/Tools/TXAdapter'
      sss.dependency 'oneCommonLib/Tools/Category'
      sss.dependency 'oneCommonLib/Tools/LogFilesManager'
    end

    # 定义 'ZFPlayer' 子规范
    # ss.subspec 'ZFPlayer' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/视频播放器/**/*.{h,m}'
    #   # sss.dependency 'oneCommonLib/Tools/Header'
    #   # sss.dependency 'oneCommonLib/Tools/TXAdapter'
    #   sss.dependency 'oneCommonLib/Tools/Category'
    #   sss.dependency 'oneCommonLib/Tools/LogFilesManager'
    # end

    # 定义 'UIKitCategory' 子规范
    ss.subspec 'UIKitCategory' do |sss|
      sss.source_files = 'oneCommonLib/Tools/自定义/**/*.{h,m}'
      # sss.dependency 'oneCommonLib/Tools/Header'
      # sss.dependency 'oneCommonLib/Tools/TXAdapter'
      sss.dependency 'oneCommonLib/Tools/Category'
      # sss.dependency 'oneCommonLib/Tools/LogFilesManager'
    end

    # 定义 'OneService' 子规范
    ss.subspec 'OneService' do |sss|
      sss.source_files = 'oneCommonLib/Tools/OneService/**/*.{h,m}'   
      sss.dependency 'oneCommonLib/Tools/PPNetworkHelper'
      sss.dependency 'oneCommonLib/Tools/Header'
      sss.dependency 'oneCommonLib/Tools/Category'
      sss.dependency 'oneCommonLib/Tools/LogFilesManager'
      sss.dependency 'oneCommonLib/Tools/NSObject'
    end

    # 定义 'PPNetworkHelper' 子规范
    ss.subspec 'PPNetworkHelper' do |sss|
      sss.source_files = 'oneCommonLib/Tools/PPNetworkHelper/**/*.{h,m}'      
    end

    # # 定义 'YBPopupMenu' 子规范
    # ss.subspec 'YBPopupMenu' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/YBPopupMenu/**/*.{h,m}'
    #   sss.dependency 'oneCommonLib/Tools/Header'
    # end

    # # 定义 'RobotSystem' 子规范
    # ss.subspec 'RobotSystem' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/RobotSystem/**/*.{h,m}'
    #   sss.dependency 'oneCommonLib/Tools/Header'
    # end

    # # 定义 'SYTimer' 子规范
    # ss.subspec 'SYTimer' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/SYTimer/**/*.{h,m}'      
    # end

    # # 定义 'UIButton' 子规范
    # ss.subspec 'UIButton' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/UIButton/**/*.{h,m}'     
    #   sss.dependency 'oneCommonLib/Tools/Header' 
    #   sss.dependency 'oneCommonLib/Tools/UIViewCategory'    
    # end

    # # 定义 'UIViewCategory' 子规范
    # ss.subspec 'UIViewCategory' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/UIViewCategory/**/*.{h,m}'   
    #   sss.dependency 'oneCommonLib/Tools/Header'   
    # end

    # # 定义 'XHPopupView' 子规范
    # ss.subspec 'XHPopupView' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/XHPopupView/**/*.{h,m}'
    # end

    # # 定义 'XHPKit' 子规范
    # ss.subspec 'XHPKit' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/XHPKit/**/*.{h,m}'
    # end

    # # 定义 'XHLaunchAd' 子规范
    # ss.subspec 'XHLaunchAd' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/XHLaunchAd/**/*.{h,m}'
    # end

    # # 定义 'Support' 子规范
    # ss.subspec 'Support' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/Support/**/*.{h,m}'
    # end

    # # 定义 'MTUI' 子规范
    # ss.subspec 'MTUI' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/MTUI/**/*.{h,m}'
    # end

    # # 定义 'LEEAlert' 子规范
    # ss.subspec 'LEEAlert' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/LEEAlert/**/*.{h,m}'
    # end

    # # 定义 'Device' 子规范
    # ss.subspec 'Device' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/Device/**/*.{h,m}'
    # end

    # # 定义 'Album' 子规范
    # ss.subspec 'Album' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/Album/**/*.{h,m}'
    # end

    # # 定义 'HJViewStyle' 子规范
    # ss.subspec 'HJViewStyle' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/渐变/**/*.{h,m}'
    # end

    # # 定义 'JXCategory' 子规范
    # ss.subspec 'JXCategory' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/顶部滑动栏/**/*.{h,m}'
    # end

    # # 定义 'YJH_MyProgressHUD' 子规范
    # ss.subspec 'YJH_MyProgressHUD' do |sss|
    #   sss.source_files = 'oneCommonLib/Tools/YJH_MyProgressHUD/**/*.{h,m}'
      
    #   # 可选：定义资源包
    #   # sss.resource_bundles = {
    #   #   'YJH_MyProgressHUD' => ['oneCommonLib/Tools/YJH_MyProgressHUD/*.{xib,json,html,jpg,gif,png,xcassets,plist,bundle,geojson}']
    #   # }
    # end
  end

  # 定义 'UserManager' 子规范
  s.subspec 'UserManager' do |ss|
    # ss.source_files = 'oneCommonLib/UserManager/*.{h,m}'
    # 指定依赖
    ss.dependency 'oneCommonLib/Tools/NSObject'

    # 定义 'clientService' 子规范
    ss.subspec 'clientService' do |sss|
      sss.source_files = 'oneCommonLib/UserManager/clientService/**/*.{h,m}'     
      sss.dependency 'oneCommonLib/Tools/OneService'
      sss.dependency 'oneCommonLib/UserManager/MSUserManager'
    end

    # 定义 'MSUserManager' 子规范
    ss.subspec 'MSUserManager' do |sss|
      sss.source_files = 'oneCommonLib/UserManager/MSUserManager/**/*.{h,m}'  
      sss.dependency 'oneCommonLib/UserManager/model'   
    end

    # 定义 'model' 子规范
    ss.subspec 'model' do |sss|
      sss.source_files = 'oneCommonLib/UserManager/model/**/*.{h,m}'     
    end
  end

  # 定义资源包
  s.resource_bundles = {
    'oneCommonLib' => ['oneCommonLib/**/*.{xib,json,html,jpg,gif,png,xcassets,plist,bundle,geojson}']
  }

  # 可选：指定为静态框架
  # s.static_framework = true

  # 指定依赖
  s.dependency 'EasyNavigation'
  s.dependency 'YYKit'
  s.dependency 'AFNetworking'
  s.dependency 'Masonry'
  s.dependency 'MJExtension'
  s.dependency 'MJRefresh'
  s.dependency 'ZipArchive'
  s.dependency 'CocoaLumberjack'
  s.dependency 'BGFMDB'
  s.dependency 'hpple'
  s.dependency 'MBProgressHUD+JDragon'


  # s.user_target_xcconfig = { 'ENABLE_BITCODE' => 'NO' }
  # 设置用户目标的 Xcode 配置
  s.user_target_xcconfig = { 'EXCLUDED_ARCHS[sdk=iphonesimulator*]' => 'arm64' }
  # 设置 Pod 目标的 Xcode 配置
  s.pod_target_xcconfig = { 'EXCLUDED_ARCHS[sdk=iphonesimulator*]' => 'arm64', 'VALID_ARCHS' => 'arm64 armv7 x86_64' }

end
